package com.thejupitech;

import android.view.View;
import android.widget.Button;
import android.widget.ImageView;
import android.widget.TextView;


public class StoreWrapper {
	View base;
	ImageView storeIcon = null;
	TextView  storeName = null;
	TextView price = null;
	TextView shipping = null;
	TextView total = null;
	Button btnBuy = null;
	
	public StoreWrapper(View base) {
		this.base = base;		
	}

	public ImageView getStoreIcon() {
		if(storeIcon==null)
			storeIcon = (ImageView)base.findViewById(R.id.store_icon);
		return storeIcon;
	}

	public TextView getStoreName() {
		if(storeName==null)
			storeName = (TextView)base.findViewById(R.id.store_name_details);
		return storeName;
	}

	public TextView getPrice() {
		if(price==null)
			price = (TextView)base.findViewById(R.id.price_details);
		return price;
	}

	public TextView getShipping() {
		if(shipping==null)
			shipping = (TextView)base.findViewById(R.id.shipping_details);
		return shipping;
	}

	public TextView getTotal() {
		if(total==null)
			total = (TextView)base.findViewById(R.id.total_details);
		return total;
	}
	
	public Button getBuyButton() {
		if(btnBuy == null)
			btnBuy = (Button)base.findViewById(R.id.buy_btn);
		return btnBuy;
	}
	
}
